﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Shared/Site.Master" AutoEventWireup="true"
    CodeBehind="QuanLyDonViTinh.aspx.cs" Inherits="Hotel_Admin.QuanLyDonViTinh" %>

<%@ Register Assembly="Hotel.Controls" Namespace="Hotel.Controls" TagPrefix="hotel" %>
<asp:Content ID="Content1" ContentPlaceHolderID="HeadContent" runat="server">
    <style type="text/css">
        
    </style>
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="MainContent" runat="server">
    <div class="crmcontainer">
        <asp:UpdatePanel runat="server" ID="upInfor" UpdateMode="Conditional">
            <ContentTemplate>
                <table class="crmtable">
                    <tbody>
                        <tr>
                            <td class="crmcell right">
                                Mã đơn vị tính
                            </td>
                            <td>
                                <asp:TextBox ID="txtMaDVT" ReadOnly="true" runat="server"></asp:TextBox>
                            </td>
                        </tr>
                        <tr>
                            <td class="crmcell right">
                                Tên đơn vị tính
                            </td>
                            <td>
                                <asp:TextBox ID="txtTenDVT" Width="200px" runat="server"></asp:TextBox>
                            </td>
                        </tr>
                        <tr>
                            <td>
                                &nbsp;
                            </td>
                            <td>
                                <asp:Button ID="btnFilter" CssClass="btnGui" Text="Lọc" runat="server" 
                                    onclick="btnFilter_Click" />
                                <asp:Button ID="btnSave" CssClass="btnGui" Text="Lưu" runat="server" 
                                    onclick="btnSave_Click" />
                                <asp:Button ID="btnDelete" CssClass="btnGui" Text="Xóa" runat="server" 
                                    onclick="btnDelete_Click" />
                                <asp:Button ID="btnHuy" CssClass="btnGui" Text="Hủy" runat="server" 
                                    onclick="btnHuy_Click" />
                            </td>
                        </tr>
                    </tbody>
                </table>
            </ContentTemplate>
        </asp:UpdatePanel>
        <asp:UpdatePanel runat="server" ID="upGird" UpdateMode="Conditional">
            <ContentTemplate>
                <hotel:Grid ID="gvList" runat="server" UseCustomPager="true" OnRowCommand="gvList_RowCommand">
                    <PagerSettings FirstPageText="loại phòng " PageButtonCount="2" />
                    <Columns>
                        <asp:TemplateField HeaderStyle-CssClass="checkbox">
                            <HeaderTemplate>
                                <input id="chkAllTop" title="Chọn hết / Bỏ chọn hết" name="chkAllTop" type="checkbox"
                                    onclick="CheckAllItems(this);" />
                            </HeaderTemplate>
                            <ItemTemplate>
                                <input id="Id" runat="server" type="hidden" value='<%# Eval("MaDonViTinh") %>' />
                                <input name="listIds" type="checkbox" value='<%# Eval("MaDonViTinh") %>' />
                            </ItemTemplate>
                        </asp:TemplateField>
                        <asp:TemplateField HeaderText="Mã đơn vị tính" HeaderStyle-Width="18%">
                            <ItemTemplate>
                                <asp:LinkButton ID="lnkBtnID" runat="server" CommandArgument='<%# Eval("MaDonViTinh") %>'
                                    CommandName="EditItem" CssClass="link" Text='<%# Eval("MaDonViTinh") %>'></asp:LinkButton>
                            </ItemTemplate>
                            <ItemStyle Font-Bold="True" />
                        </asp:TemplateField>
                        <asp:BoundField DataField="TenDonViTinh" HeaderText="Tên Đơn Vị Tính" />
                    </Columns>
                </hotel:Grid>
            </ContentTemplate>
        </asp:UpdatePanel>
    </div>
</asp:Content>
